load("@rules_rust//rust:defs.bzl", "rust_doc_test", "rust_library", "rust_test")

package(default_visibility = ["//visibility:public"])

rust_library(
    name = "lru_cache",
    srcs = glob(["src/**"]),
    crate_name = "ic_utils_lru_cache",
    version = "0.1.0",
    deps = [
        # Keep sorted.
        "//packages/ic-heap-bytes",
        "//rs/types/types",
        "@crate_index//:lru",
    ],
)

rust_test(
    name = "lru_cache_test",
    crate = ":lru_cache",
    deps = [
        "@crate_index//:proptest",
    ],
)

rust_doc_test(
    name = "lru_cache_doc_test",
    crate = ":lru_cache",
)
